package cn.buk.tms.dto;

/**
 * 用于在内部传递当前用户的认证信息
 */
public class AuthInfo {

  private final int enterpriseId;
  private final int userId;
  private final String username;

  public static AuthInfo createAuthInfo(int enterpriseId, int userId, String username) {
    return new AuthInfo(enterpriseId, userId, username);
  }

  public AuthInfo(int enterpriseId, int userId, String username) {
    this.enterpriseId = enterpriseId;
    this.userId = userId;
    this.username = username;
  }

  public int getEnterpriseId() {
    return enterpriseId;
  }

  public int getUserId() {
    return userId;
  }

  public String getUsername() {
    return username;
  }
}
